#include "AnimalFactory.h"
#include <string> 
#include "Human.h"
AnimalFactory* AnimalFactory::single_instance = 0;

AnimalFactory* AnimalFactory::get_instance()
{
	if(single_instance == 0)
		single_instance = new AnimalFactory();
	return single_instance;
}
Animal* AnimalFactory::create_animal(std::string type,std::string dna)
{
	Animal* animal;
	
	if(type=="Human")
	{
		animal=new Human(animals_.size(),dna); 
	}
	
	animals_.push_back(animal);
	return animal;
}

